# Maintainer: Felix Yan <felixonmars@archlinux.org>

pkgname=python-big-o
pkgver=0.11.0
_commit=359971f6cb270d10cbd35909eeb3763717ea2e2b
pkgrel=1
pkgdesc="Empirical estimation of time complexity from execution time"
url="https://github.com/pberkes/big_O"
license=('BSD')
arch=('any')
depends=('python-numpy')
makedepends=('git' 'python-build' 'python-installer' 'python-setuptools' 'python-wheel')
checkdepends=('python-pytest')
source=("git+https://github.com/pberkes/big_O.git#commit=$_commit")
sha512sums=('SKIP')

build() {
  cd big_O
  python -m build -nw
}

check() {
  cd big_O
  pytest
}

package() {
  cd big_O
  python -m installer -d "$pkgdir" dist/*.whl
  install -Dm644 LICENSE.txt -t "$pkgdir"/usr/share/licenses/$pkgname/
}
